package net.vanchu.mortgagecalculator.mortgage.calculate.mix;

import net.vanchu.mortgagecalculator.common.commonView.component.WritingOptionLayout;
import net.vanchu.mortgagecalculator.common.config.LoanRate;
import net.vanchu.mortgagecalculator.common.config.LoanWay;

/**
 * Created by Granton on 2016/12/21.
 */
public interface CalMixLoanContract {

    interface View {
        void showLoanYear(String yearExpress);

        void showCommercialLoanRate(String rateExpress);

        void showProvidentFundRate(String rateExpress);

        void showEnableCalButton();

        void showDisableCalButton();

        void showLoanWays();

        void showLoanYears();

        void showProvidentFundLoanRates();

        void showCommercialLoanRates();

        void tipError(String s);

        void resetComLoanRates();

        void resetProLoanRates();
    }

    interface Presenter {
        void chooseLoanWay(LoanWay loanWay);

        void preChooseLoanWay();

        void chooseLoanYear(int year);

        void chooseComLoanRates(LoanRate loanRate, float discount);

        void chooseProLoanRates(LoanRate loanRate, float discount);

        void preChooseLoanYear();

        void preChooseComLoanRates();

        void preChooseProLoanRates();

        void applyCalculate();

        WritingOptionLayout.InputStateListener asInputStateListener();

        WritingOptionLayout.InputValidator asInputValidator();
    }
}